<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        <my-com :msg="abc" :msg1="bb"></my-com>
    </div>
    <script src="./node_modules/vue/dist/vue.js"></script>
    <script>
        Vue.component('my-com',{
            props:{
                msg:{
                    type:String,
                    required:true 
                },
                msg1:{
                    type:Array,
                    required:true 
                }
            },
            template:`
                <div>
                    {{msg}}    
                </div>
            `,
            watch:{
                msg1:function(){
                    console.log(111)
                }
            }
        })
        var vm = new Vue({
            el:'#app',
            data:{
                abc:'aa',
                bb:[1,2,3]
            },
            methods:{
                
            }
        })
    </script>
</body>
</html>
